<template>
   <i class="iconfont" :class="classType" :style="{
       fontSize:size+'px'
   }"></i>
</template>

<script>
const classMap = {
    home:'icon-shouye',
    blog:'icon-wenzhang',
    project:"icon-faxiangmu",
    about:"icon-bangzhuguanyuwomen",
    message:"icon-xiaoxi",
    github:"icon-github-fill",
    qq:"icon-QQ-circle-fill",
    weixin:"icon-weixin-copy",
    note:"icon-duanxin",
    error:"icon-cuowu",
    success:"icon-zhengque",
    empty:"icon-kong",
    close:"icon-guanbi",
    warn:"icon-jinggao",
    arrowUp:"icon-xialajiantou1",
    arrowDown:"icon-xiajiantou"
}
export default {
 name:'Icon',
 props:{
     type:{
         type:String,
         require:true
     },
     size:{
         type:Number,
         default:16
     }
 },
 computed:{
     classType(){
         return classMap[this.type];
     }
 }
}
</script>

<style>
@import "//at.alicdn.com/t/font_2992506_m5sqkn6hyz.css";

</style>